@model IEnumerable<IDocument>

@{
    foreach (IDocument post in Model)
    {
        string lead = post.String(BlogKeys.Lead);
        
        <div>
            <a href="@Context.GetLink(post)">
                <h2>@post.WithoutSettings.String(BlogKeys.Title)</h2>
            </a>
            @if(!string.IsNullOrWhiteSpace(lead))
            {
                <p>@lead</p>
            }
            <p><em>Posted on @(post.Get<DateTime>(BlogKeys.Published).ToLongDateString(Context))</em></p>      
            @if(Context.Bool(BlogKeys.ArchiveExcerpts))
            {
                @Html.Raw(post.String(BlogKeys.Excerpt))
            }
        </div>   
    }
}